from rest_framework import serializers

class Userser(serializers.Serializer):
    name = serializers.CharField(max_length=200)
    password = serializers.CharField(max_length=200)
    tel = serializers.IntegerField()
    id = serializers.IntegerField()
    vip = serializers.IntegerField()

    class Meta:
        db_table = 'user'

class Goodser(serializers.Serializer):
    name = serializers.CharField(max_length=200)
    price = serializers.CharField(max_length=200)
    vip_price = serializers.CharField(max_length=200)
    img = serializers.CharField(max_length=200)
    id = serializers.IntegerField()
    class Meta:
        db_table = 'good'

class Dingser(serializers.Serializer):
    uid = Userser()
    gid = Goodser()

    class Meta:
        db_table = 'ding'




